package collection;

import java.util.ArrayList;
import java.util.Collection;

public class CollectionDemo5 {
    public static void main(String[] args) {
        Collection<String> c = new ArrayList<>();
        c.add("one");
        //c.add(123);//编译错误,123不是String类型
    }
}
